//
//  BaseListVC.m
//  QuDanOEM
//
//  Created by wmz on 2021/11/5.
//

#import "BaseListVC.h"

@interface BaseListVC ()

@end

@implementation BaseListVC

- (instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil{
    return [super initWithNibName:NSStringFromClass([self.superclass class]) bundle:nibBundleOrNil];;
}

- (void)hd_setupViews{
    self.showConfirm = NO;
    self.tableView.GNdelegate = self;
    self.confirmBTN.backgroundColor = [UIColor bm_colorGradientChangeWithSize:CGSizeMake(PostWidth - 36, 40) direction:PageGradientChangeDirectionLevel startColor:PostColorP(0xFF5121,1) endColor:PostColorP(0xFFC021,1)];
}

- (void)setShowConfirm:(BOOL)showConfirm{
    _showConfirm = showConfirm;
    self.heightLayout.constant = showConfirm ? 44:0;
    self.topLayout.constant = showConfirm ? 10:0;
    self.bottomLayout.constant = showConfirm ? 10:0;
}

- (NSMutableArray *)dataSource{
    if (!_dataSource) {
        _dataSource = NSMutableArray.new;
    }
    return _dataSource;
}
@end
